//
//  GroupGoingViewCell.m
//  PASystem
//
//  Created by 刘沿 on 16/8/28.
//  Copyright © 2016年 czd. All rights reserved.
//

#import "GroupGoingViewCell.h"

@implementation GroupGoingViewCell

+ (instancetype)WithGroupGoingViewCell{

    return [[[NSBundle mainBundle] loadNibNamed:@"GroupGoingViewCell" owner:nil options:nil] lastObject];
}

-(void)setModel:(GroupGoingModel *)model{
    
    _model = model;
    self.NAME.text = model.NAME;
    self.LINKMAN.text = model.LINKMAN;
    self.PHONE.text = model.PHONE;
    self.HOUSE.text = model.HOUSE;
    self.BOOTHNUMBER.text = model.BOOTHNUMBER;
    //时间戳
    NSString *string = model.GOTIME;
    NSDateFormatter *fmt = [[NSDateFormatter alloc] init];
    fmt.dateFormat = @"MMM d, yyyy HH:mm:ss aa";
    fmt.locale = [[NSLocale alloc] initWithLocaleIdentifier:@"en-US"];
    NSDate *date = [fmt dateFromString:string];
    NSDateFormatter *fm = [[NSDateFormatter alloc] init];
    fm.dateFormat = @"yyyy-MM-dd";
    NSString *selfYear = [fm stringFromDate:date];

    self.GOTIME.text = selfYear;
}




@end
